<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" >
<!--[if lt IE 9]>
　　　　<script src="http://css3-mediaqueries-js.googlecode.com/svn/trunk/css3-mediaqueries.js"></script>
　　<![endif]-->
<link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/sytle.css?v=0.2&d=2016-11-08">
<title>添加新地址</title>
</head>
<script type="text/javascript" src="${pageContext.request.contextPath}/lib/jquery/1.9.1/jquery.min.js?v=0.1"></script> 
<script type="text/javascript">
$(document).ready(function(){
	
	 	
   
 	$("#btn_sub").click(function(){
 		var is = true;
		var street = $("#street").val();
	   	if(street == '') {
	   		$("#tip").show();
	    	$("#tipMsg").text("请输入您的小区或街道名");
	   		
		  	is = false; 
		  	close();
	   	}
	    var houseNumber =  $("#houseNumber").val();
	    if(houseNumber == '') {
	    
	    	$("#tip").show();
	    	$("#tipMsg").text("请输入您的门牌号");
		  	is = false; 
		  	close();
	   	}
	   var wCContact =  $("#wCContact").val();
	    if(wCContact == '') {
	    	
	    	$("#tip").show();
	    	$("#tipMsg").text("请输入您的姓名");
		  	is = false; 
		  	close();
	   	}
	   	if(is) {
	   		$("#commentForm").submit();
	   	}
	    var wCTelephone =  $("#wCTelephone").val();
	    if(wCTelephone == '' || wCTelephone.length < 10 || isNaN(wCTelephone)) {
	    	
	    	$("#tip").show();
	    	$("#tipMsg").text("请输您的手机号码");
		  	is = false; 
		  	close();
	   	}
 	   	if(is) {
 	   		$("#addForm").submit();
 	   	}
 	});
 	
 
}); 

function close() {
 	setTimeout(function() {
 		$("#tip").hide();
 	}, 2000);
}
</script> 
<body>
<form ${pageContext.request.contextPath}/members/addContact.html" method="POST" id="addForm">
<input type="hidden" name="wCCity" value="重庆" />
<div class="hgj">
  <div class="page-all" style=" margin-bottom:0;">
    <div class="container">
      <div class="address-list">
        <div class="seclect-input">
          <select name="wCDistrict">
            <option value="九龙坡区">九龙坡区</option>
            <option value="江北区">江北区</option>
            <option value="渝北区">渝北区</option>
            <option value="渝中区">渝中区</option>
            <option value="南岸区">南岸区</option>
            <option value="沙坪坝区">沙坪坝区</option>
          </select>
        </div>
      </div>
       <div class="adr-list">
          <div class="adr-list-left"><img src="${pageContext.request.contextPath}/images/adr-icon.png"/></div>
          <div class="adr-list-right">
            <input type="text" class="in-btn" name="street" id="street" placeholder="请输入您的小区或街道名">
          </div>
        </div>
      <div class="adr-list">
        <div class="adr-list-left"><img src="${pageContext.request.contextPath}/images/buli-icon.png"/></div>
        <div class="adr-list-right">
          <input type="text" class="in-btn" name="houseNumber" id="houseNumber" placeholder="请输入您的门牌号">
        </div>
      </div>
      <div class="adr-list">
        <div class="adr-list-left"><img src="${pageContext.request.contextPath}/images/user-icon.png"/></div>
        <div class="adr-list-right">
          <input type="text" class="in-btn" name="wCContact" id="wCContact" placeholder="请输入您的姓名">
        </div>
      </div>
      <div class="adr-list">
        <div class="adr-list-left"><img src="${pageContext.request.contextPath}/images/tel-icon.png"/></div>
        <div class="adr-list-right">
          <input type="text" class="in-btn" name="wCTelephone" id="wCTelephone" placeholder="请输入您的手机号码">
        </div>
      </div>
    </div>
    <div class="login-layer" style=" display:none;" id="tip"> <span id="tipMsg"></span> </div>
    <footer>
<a href="javascript:void();" class="sumit-btn" id="btn_sub">确认添加</a>
</footer>
  </div>
</div>
</form>
</body>
</html>
